package com.wgts.wgts.mvp.model.imp;

import com.wgts.wgts.mvp.model.IShippingAddressActivityModel;
import com.wgts.wgts.netmodle.HttpResultSubscriber;
import com.wgts.wgts.netmodle.NetService;
import com.wgts.wgts.netmodle.resp.CurrentEntity;
import com.wgts.wgts.netmodle.resp.ShippingAddressEntity;

import java.util.List;

/*
 *
 *
 *   data:2018/10/49:18
 *
 */public class ShippingAddressActivityModel implements IShippingAddressActivityModel {
     private NetService netService;

    public ShippingAddressActivityModel(NetService netService) {
        this.netService = netService;
    }

    @Override
    public void getShippingAddress(HttpResultSubscriber<List<ShippingAddressEntity>> subscriber) {
        netService.shippingAddress(subscriber);
    }

    @Override
    public void normalAddressResult(String addressId, HttpResultSubscriber<CurrentEntity> subscriber) {
        netService.normalAddress(addressId, subscriber);
    }

    @Override
    public void deleteAddress(String addressId, HttpResultSubscriber<CurrentEntity> subscriber) {
        netService.deleteAddress(addressId, subscriber);
    }
}
